home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_actor_boomthing.cog < prev    next >
Text File  |  1999-11-15  |  956b  |  50 lines

  1. # Jones 3D Cog Script
  2. #
  3. # actor_BoomThing.cog
  4. #
  5. # [RT]
  6. #
  7. # Ignore damage from fists, whip and machete.
  8. #
  9. # (C) 1999 LucasArts Entertainment Company LLC. All Rights Reserved
  10. #
  11. # ===================================================================
  12.  
  13. symbols
  14.  
  15.     message        damaged
  16.  
  17.     sound        punch=gen_fists_fire.wav            local
  18.     sound        crunch=gen_machete_hit_metal.wav    local
  19.  
  20.     thing         sender                                local
  21.  
  22.     int            damageType                            local
  23.  
  24. end
  25.  
  26. # ===================================================================
  27.  
  28. code
  29.  
  30. # -------------------------------------------------------------------
  31.  
  32. damaged:
  33.  
  34.     damageType = GetParam(1);
  35.  
  36.     if (BitTest(damageType, 0x8 | 0x10 | 0x20))
  37.     {
  38.         sender = GetSenderRef();
  39.         
  40.         if (BitTest(damageType, 0x8))
  41.             PlaySoundThing(punch, sender, 1, -1, -1, 0x880);
  42.         else if (BitTest(damageType, 0x20))
  43.             PlaySoundThing(crunch, sender, 1, -1, -1, 0x880);
  44.  
  45.         ReturnEx(0);
  46.     }
  47.  
  48.     return;
  49.  
  50. end